div(ng-controller='RuleListProfileCtrl')
  section.settings-group
    h3 {{'options_group_ruleListConfig' | tr}}
    .form-group
      label {{'options_ruleListMatchProfile' | tr}}
      = ' '
      div(omega-profile-select='options | profiles:profile' ng-model='profile.matchProfileName'
        disp-name='dispNameFilter' options='options' style='display: inline-block;')
    .form-group
      label {{'options_ruleListDefaultProfile' | tr}}
      = ' '
      div(omega-profile-select='options | profiles:profile' ng-model='profile.defaultProfileName'
        disp-name='dispNameFilter' options='options' style='display: inline-block;')
    form.form-group
      label {{'options_ruleListFormat' | tr}}
      .radio.inline-form-control.no-min-width(ng-repeat='format in ruleListFormats')
        label
          input(type='radio' name='formatInput' value='{{format}}' ng-model='profile.format')
          | {{'ruleListFormat_' + format | tr}}
  section.settings-group
    h3 {{'options_group_ruleListUrl' | tr}}
    .width-limit(input-group-clear type='url' model='profile.sourceUrl' ng-if='profile')
    p.help-block {{'options_ruleListUrlHelp' | tr}}
  section.settings-group
    h3 {{'options_group_ruleListText' | tr}}
    p
      button.btn.btn-default(ng-disabled='!profile.sourceUrl' ng-click='updateProfile(profile.name)'
          ladda='updatingProfile[profile.name]' data-spinner-color="#000000")
        | #[span.glyphicon.glyphicon-download-alt] {{'options_downloadProfileNow' | tr}}
    textarea.monospace.form-control.width-limit(ng-model='profile.ruleList' rows=20
      ng-disabled='!!profile.sourceUrl')

